package qnb.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import qnb.dao.TeacherMapper;
import qnb.entity.Teacher;
import qnb.service.TeacherService;

@Service
public class TeacherServiceImpl implements TeacherService {

	@Autowired
	private TeacherMapper teacherMapper;

	@Override
	public List<Teacher> selectAllByTeacherName() {
		return teacherMapper.selectAllByTeacherName();
	}

	@Override
	public List<Teacher> selectAllTeacher() {
		return teacherMapper.selectAllTeacher();
	}

	@Override
	public Integer insertTeacher(Teacher teacher) {
		return teacherMapper.insertTeacher(teacher);
	}

	@Override
	public Integer deleteTeacher(Integer teacher_id) {
		return teacherMapper.deleteTeacher(teacher_id);
	}

	@Override
	public Integer updateTeacher(Teacher teacher) {
		return teacherMapper.updateTeacher(teacher);
	}

}
